---
title: "Integración en la UE"
author: "Alba Nuez Vilà"
output:
flexdashboard::flex_dashboard:
orientation: rows
vertical_layout: fill
social: menu
source_code: embed
---
```{r setup, include=FALSE}
#Librerías de interés
library(flexdashboard)
library(tidyverse)
library(maps)
library(plotly)
library(shiny)
library(readxl)
library(dplyr)
```
```{r}
#Cargamos la base de datos depurada
df <- read_excel("Depurada_ESS11_subset.xlsx")
#La variable país debe ser un factor
df$cntry <- as.factor(df$cntry)
```
Column {data-width=650}
-----------------------------------------------------------------------
### Chart A
```{r}
# UI setup for reactive inputs
shiny::selectInput('cntry', 'Selecciona un país:', choices = levels(df$cntry), selected = levels(df$cntry)[1])
# Plotly map of Europe
plot_ly(
type = 'choropleth',
locations = df$cntry,
locationmode = 'ISO-3',
z = df$some_metric, # Replace with a relevant metric
colorscale = 'Viridis',
colorbar = list(title = 'Metric')
) %>%
layout(title = 'Europe Map')
```
Column {data-width=200}
-----------------------------------------------------------------------
### Chart B
```{r}
table(df$cntry)
```
### Chart C
```{r}
```
### Chart D
```{r}
```